import numpy as np
# Feature Scaling Implementation 
# Write a Python function that performs feature scaling 
# on a dataset using both standardization and min-max normalization. 
# The function should take a 2D NumPy array as input, 
# where each row represents a data sample and each column represents a feature. 
# It should return two 2D NumPy arrays: 
#   one scaled by standardization and one by min-max normalization. 
# Make sure all results are rounded to the nearest 4th decimal.

def feature_scaling(data: np.ndarray) -> (np.ndarray, np.ndarray):
    mean = np.mean(data, axis=0)
    std = np.std(data, axis=0)
    standardized_data = (data - mean) / std
    
    # Min-Max Normalization
    min_val = np.min(data, axis=0)
    max_val = np.max(data, axis=0)
    min_max_normalized_data = (data - min_val) / (max_val - min_val)
    
    return np.round(standardized_data, 4), np.round(min_max_normalized_data, 4)